package com.lovely3x.library.activityies;

import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.NonNull;

import com.lovely3x.common.activities.CommonActivity;
import com.lovely3x.umeng.social.library.R;

/**
 * 分享界面
 * Created by lovely3x on 17/3/16.
 */
public class ShareActivity extends BlurShareActivity {

    public static void launchMe(@NonNull CommonActivity activity, @NonNull com.lovely3x.library.benas.ShareContent shareContent) {
        Intent intent = new Intent(activity, ShareActivity.class);
        intent.putExtra(EXTRA_SHARE_CONTENT, shareContent);
        activity.startActivity(intent);
    }

    public static void launchMe(@NonNull CommonActivity activity, @NonNull com.lovely3x.library.benas.ShareContent shareContent, int requestCode) {
        launchMe(activity, shareContent, null, requestCode);
    }

    public static void launchMe(@NonNull CommonActivity activity, @NonNull com.lovely3x.library.benas.ShareContent shareContent, Object callBackExtra, int requestCode) {
        Intent intent = new Intent(activity, ShareActivity.class);
        Bundle bundle = activity.buildBundle(EXTRA_SHARE_CONTENT, shareContent, EXTRA_CALLBACK_OBJECT, callBackExtra);
        intent.putExtras(bundle);
        activity.startActivityForResult(intent, requestCode);
    }

    protected int getContentView() {
        return R.layout.activity_share;
    }

    @Override
    public void onCancelClicked() {
        finish();
    }

    @Override
    protected void playEnterAnim() {

    }

    @Override
    protected void playFinishAnim() {

    }
}
